import  turtle
def koch(len,n,a):
    if n==0:
        turtle.fd(len)
    else:
        for i in a:
            turtle.left(i)
            koch(len/3,n-1,a)
turtle.penup()
turtle.goto(-300,0)
turtle.pendown()
turtle.pensize(3)
a=[0,60,-120,60]
koch(600,4,a)
turtle.hideturtle()
turtle.done()